package com.lefevre.cms.bean.mediaProcess;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.persistence.*;
import java.io.Serializable;

/**
 * 媒体处理设置
 *
 * @author Lefevre
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("media_process_setting")
@Entity
@Table(name = "media_process_setting")
public class MediaProcessSetting implements Serializable {
    private static final long serialVersionUID = -7938266500098151340L;

    @Id
    @TableId(type = IdType.INPUT)
    private Integer id;

    /**
     * 切片每段时长 单位/秒
     **/
    @TableField("segmentTime")
    private Integer segmentTime = 10;

    /**
     * 使用水印
     **/
    @TableField("watermark")
    private Boolean watermark = false;

    /**
     * 水印文件路径名称
     **/
    @TableField("watermarkFullPathName")
    private String watermarkFullPathName;

    /**
     * 水印位置 10:左上角 20:右上角 30:右下角 40:左下角
     **/
    @TableField("watermarkPosition")
    private Integer watermarkPosition = 10;

    /**
     * 水印水平距离
     **/
    @TableField("watermarkDistance_x")
    private Integer watermarkDistance_x = 10;

    /**
     * 水印垂直距离
     **/
    @TableField("watermarkDistance_y")
    private Integer watermarkDistance_y = 10;

    /**
     * 帧速率 24表示每秒24帧 空表示采用源视频帧速率
     **/
    @TableField("videoFrameRate")
    private Integer videoFrameRate;

    /**
     * 切片地点 0:无 10:本地切片 20:远程切片 30:本地切片+远程切片
     **/
    @TableField("segmentLocation")
    private Integer segmentLocation = 0;

    /**
     * 远程切片验证密钥
     **/
    @Column(length = 100)
    @TableField("remoteSegmentSecret")
    private String remoteSegmentSecret;

    /**
     * 版本
     **/
    @Version
    private Long version = 0L;

}
